import com.cloudbroker.bcs.common.util.MD5Util;
import com.cloudbroker.bcs.csvc.uc.api.vo.request.FuncAdviserForm;
import com.cloudbroker.bcs.csvc.uc.api.vo.response.AdviserInfoVo;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.HashMap;
import java.util.Map;

/**
 * Created by hspcadmin on 2017/2/15.
 */

public class test {


    public void test(){
        FuncAdviserForm funcAdviserForm = new FuncAdviserForm();
        funcAdviserForm.setUser_ids("343173");
        funcAdviserForm.setSource("cloudbroker_1");
        funcAdviserForm.setSign(genSign("cloudbroker_1","B17B4A0854FCEDF370380F3FD3FBA56C"));
//        AdviserInfoVo adviserInfoVo = uCenterService.funcAdviserGet(funcAdviserForm);
    }

    public static String genSign(String source,String signKey){
        Map<String, String> map=new HashMap<>();
        map.put("source", source);
        map.put("signKey", signKey);
        String checkSign = MD5Util.encrypt(map.toString());
        return checkSign;
    }
}
